package com.sinochem.yunlian.ship.common.enums;

import lombok.Getter;

/**
 * @Auther: zzd
 * @Dscription: 返回状态码
 * @Date: Create in 2017/11/20 14:29
 **/
public enum ResponseCode {

    /**
     * ######通用码值
              未登录 -1001
              没权限 -1002
             系统错误 -1000
     **/
    SYS_EXCEPTION(-1000,"系统繁忙，请稍后再试"),
    INVALID_TOKEN(-1001,"请登录"),
    NO_PERMISSION(-1002,"没有足够的权限"),
    INVALID_PARAM(-1003,"参数有误"),
    MESSAGE_NOET_READABLE(-1004,"序列化或反序列化出错"),
    TOO_MANY_REQUESTS(-1005,"接口请求频率超过最大次数，请稍后重试!"),
    APP_VERSION_UPDATE(-1006,"App 版本强制更新"),
    GATE_INVALID_PARAM(-1010,"参数有误!"),
    GATE_INVALID_SIGN(-1011,"签名有误!"),
    UC_ERROR_DATAFORMAT(-1012,"接口返回格式有改动"),
    UC_ERROR_HTTPTIMEOUT(-1013,"接口调用失败"),
    UC_ERROR_USERDISABLE(-1014,"当前登录用户已被禁用!"),

    //1000 通用代码
    SUCCESS(1000, "成功"),
    UN_AUTH(1001,"该功能仅对企业用户开放，请进行企业入驻或者加入企业。"),
    AUTH_FAIL(1002,"认证未通过"),
    AUTH_AUDIT(1003,"认证审核中"),
    COMPANY_NOT_EXIST(1004,"当前公司不存在"),
    AUTH_USER_FAIL(1005,"用户身份不存在"),
    WAITING_MANAGER_ACCEPT(1006,"申请加入公司等待管理员同意"),
    MANAGER_REJECT_USER_JOIN_COMPANY(1007,"管理员拒绝用户加入"),
    NICK_NAME_FAIL(1008,"昵称不存在"),
    FORBID_USER(1009,"您已被禁言"),
    NICK_NAME_EXISTED(1010,"昵称仅能设置一次"),
    NICK_NAME_UNIQUE(1011,"您的昵称已被其他人使用，请重新设置"),
    NICK_NAME_SENSITIVE(1012,"您设置的昵称中有不当词语，请修改"),
    NICK_NAME_INVALID(1013,"请查看昵称规则后，重新设置"),

    /**
     * 交易 2000+
     * */
    TRADE_NOTIFICATION(2000,"bad request"),
    INVALID_MATERIAL(2010,"无效的货盘"),
    INVALID_BID(2020,"无效的报价"),

    /**
     * 运单服务 3000+
     * */
    TRACE_NOTIFICATION(3000,"bad request"),
    PARAM_ERROR(3001,"参数不正确"),
    NOT_EXIST(3002,"请求成功但数据不存在"),
    UPDATE_FAIL(3003,"更新失败"),
    STATUS_NOT_ALLOW(3004,"不允许操作"),
    DATA_ERROR(3005,"数据库数据不正确"),
    ACTION_RE_ERROR(3006,"已请求过该操作，不能重复执行"),

    FRONT_SHOW(3020,"运单部分前端直接展示信息"),

    /**
     *  用户服务 4000+
     * */
	NOTIFICATION(4000,"前端不判断，直接弹出提示语"),
    REDIRECT_TO_JOIN_COMPANY(4001,"引导去加入公司"),
    REDIRECT_TO_DOWNLOAD_APP(4002,"引导去下载APP"),



    /**
     *  聊天 5000+
     * */
    CHAT_GROUP_ERROR(5000,"群聊操作异常"),
    EXISTED_IN_GROUP(5010,"该用户已经是群成员"),
    EXISTED_NOT_IN_GROUP(5011,"该用户已经是群成员"),
    CHAT_GROUP_PARAMS_ERROR(5020,"群消息发送：参数错误"),

    /**
     * 社区  6000+
     */
    ALREADY_ACCUSATION(6000,"已进行过举报"),
    DYNAMIC_SENSITIVE_WORDS(6100,"您发布的动态中有不当词语,请修改"),
    COMMENT_SENSITIVE_WORDS(6200,"您发布的评论中有不当词语,请修改"),

    /**
     * banner 7000+
     */
    CANNOT_MOVE_UP(7100,"第一条不能上移"),
    CANNOT_MOVE_DOWN(7101,"最后一条不能下移"),

    /**
     * 用户电话号码隐藏 8000+
     */
    USER_PHONE_ABX_SYS_ERROR(8000,"获取号码隐私保护失败"),
    USER_PHONE_ABX_ALIYUN_ERROR(8100,"阿里云服务：无可用号码"),    //NO_AVAILABLE_NUMBER
    USER_PHONE_ABX_USERINFO_ERROR(8200,"userIds对于的用户信息异常"),

    /**
     *邀请用户 9000+
     */
    USER_INVITER_CONFIRM_ERROR(9000,"验证码验证失败"),
    USER_INVITER_CONFIRM_NOT_EXIST(9100,"邀请记录不存在"),





    ;



    @Getter
    private int code;
    
    @Getter
    private String name;

    ResponseCode(int code, String name) {
        this.code = code;
        this.name = name;
    }
    
}

